/*
 * utils.h
 *
 *  Created on: 09/07/2010
 *      Author: alex
 */

#ifndef UTILS_H_
#define UTILS_H_

#include <SDL/SDL.h>
#include <string>
#include <vector>


namespace utils {


extern unsigned playerNumber;
extern unsigned numPlayers;
extern const unsigned MAX_PLAYERS;


extern const int VIDEO_WIDTH;
extern const int VIDEO_HEIGHT;
extern const int VIDEO_BPP;


extern SDL_Rect* rectCenter;


static inline SDL_Rect makeRect(int x, int y, int h, int w) {
	SDL_Rect rec;
	rec.x = x;
	rec.y = y;
	rec.h = h;
	rec.w = w;
	return rec;
}


static inline SDL_Color makeColor(unsigned char r, unsigned char g, unsigned char b) {
	SDL_Color cor;
	cor.r = r;
	cor.g = g;
	cor.b = b;
	return cor;
}


} /* namespace utils */


#endif /* UTILS_H_ */
